<?php

namespace app\mobile\controller;
use app\traits\Mobile;
use think\Controller;
use app\admin\model\Banner as BannerModel;
use app\common\model\Config;
class Base extends Controller
{
use Mobile;

    function _initialize()
    {
        $banners = BannerModel::where("languagedata","1")->select();
        $Banner = [];
        foreach ($banners as $v) {
            $Banner[$v['category_id']] = $v['image'];
        }
        $sundrtS = Config::where('group', 'basic')->select();
$sundry=[];
        foreach ($sundrtS as $v) {
            $sundry[$v['name']] = $v['value'];
        }
        $this->assign([
            'Banner' => $Banner,
            'sundry' => $sundry,

        ]);
    }
}